﻿#include "GameView.h"

#include "../../Core/Application.hpp"
#include "../../Render/RenderCommand.hpp"
#include <imgui.h>

namespace Kriko_View
{
    GameView::GameView(const std::string& name, int* textureID) : BaseView(name), textureID(textureID)
    {
        
    }

    void GameView::Render()
    {
        BeginRender();
        ImGui::Image(
            (ImTextureID)*textureID,
            ImVec2(Kriko::Application::Get().GetWindow().VGetWidth(), Kriko::Application::Get().GetWindow().VGetHeight()),
            ImVec2(0, 1),
            ImVec2(1, 0)
            );
        EndRender();
    }

    GameView::~GameView()
    {
    }
}
